<?php
namespace app\blog\form;

use app\common\loglic\Form;

class Page extends Form
{
    public function items($data=[])
    {
        return [
            'index_sort' => [
                'type'        => 'select',
                'value'       => $data['index_sort'],
                'option'      => $this->optionFlip(model('common/Sort','loglic')->detail()),
                'required'    => true,
                'title'       => '首页排序字段',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'index_limit' => [
                'type'        => 'number',
                'value'       => intval($data['index_limit']),
                'required'    => true,
                'title'       => '首页每页数量',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'index_total' => [
                'type'        => 'number',
                'value'       => intval($data['index_total']),
                'required'    => true,
                'title'       => '首页总记录数',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'index_title' => [
                'type'        => 'text',
                'value'       => $data['index_title'],
                'required'    => true,
                'title'       => '首页标题',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'index_keywords' => [
                'type'        => 'text',
                'value'       => $data['index_keywords'],
                'required'    => true,
                'title'       => '首页关键字',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'index_description' => [
                'type'        => 'text',
                'value'       => $data['index_description'],
                'required'    => true,
                'title'       => '首页描述',
                'class_row'   => 'row mb-3 border-bottom pb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'search_limit' => [
                'type'        => 'number',
                'value'       => intval($data['search_limit']),
                'required'    => true,
                'title'       => '搜索页每页数量',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'search_total' => [
                'type'        => 'number',
                'value'       => intval($data['search_total']),
                'required'    => true,
                'title'       => '搜索页总记录数',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'search_title' => [
                'type'        => 'text',
                'value'       => $data['search_title'],
                'required'    => true,
                'title'       => '搜索页标题',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'search_keywords' => [
                'type'        => 'text',
                'value'       => $data['search_keywords'],
                'required'    => true,
                'title'       => '搜索页关键字',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'search_description' => [
                'type'        => 'text',
                'value'       => $data['search_description'],
                'required'    => true,
                'title'       => '搜索页描述',
                'class_row'   => 'row mb-3 border-bottom pb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'tags_total' => [
                'type'        => 'number',
                'value'       => intval($data['tags_total']),
                'required'    => true,
                'title'       => '标签页总记录数',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'tags_title' => [
                'type'        => 'text',
                'value'       => $data['tags_title'],
                'required'    => true,
                'title'       => '标签页标题',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'tags_keywords' => [
                'type'        => 'text',
                'value'       => $data['tags_keywords'],
                'required'    => true,
                'title'       => '标签页关键字',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'tags_description' => [
                'type'        => 'text',
                'value'       => $data['tags_description'],
                'required'    => true,
                'title'       => '标签页描述',
                'class_row'   => 'row mb-3 border-bottom pb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'types_title' => [
                'type'        => 'text',
                'value'       => $data['types_title'],
                'required'    => true,
                'title'       => '分类页标题',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'types_keywords' => [
                'type'        => 'text',
                'value'       => $data['types_keywords'],
                'required'    => true,
                'title'       => '分类页关键字',
                'class_row'   => 'row mb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
            'types_description' => [
                'type'        => 'text',
                'value'       => $data['types_description'],
                'required'    => true,
                'title'       => '分类页描述',
                'class_row'   => 'row mb-3 border-bottom pb-3',
                'class_label' => 'col-2 col-form-label',
                'class_col'   => 'col-10',
            ],
        ];
    }
}